// ReSharper disable InconsistentNaming

namespace Microsoft.Web.Management.Iis.Client
{
    /// <summary>
    /// Contains a list of property bag position indexes.
    /// </summary>
    /// <remarks>
    /// These values are made public so they can be shared with the server. 
    /// This class is referenced by the server side module code to read and store 
    /// values to the configuration system. The client side module code uses 
    /// this class to read and set values to the property bag received from the 
    /// server. 
    /// </remarks>
    public static class LoggingPropertyIndexes
    {
        // TODO: Make internal
        // This class could be marked as internal and a friend assembly could
        // be specified for the build 

        // system.webServer/httpLogging
        //####################################################

        /// <summary>
        /// Represents the dontLog attribute for system.webServer/httpLogging element.
        /// </summary>
        /// <remarks>
        /// The constant value is '0'.
        /// </remarks>
        public const int HTTP_DONT_LOG_INDEX = 0;
       
        /// <summary>
        /// Represents the selectiveLogging attribute for system.webServer/httpLogging element.
        /// </summary>
        /// <remarks>
        /// The constant value is '1'.
        /// </remarks>
        public const int HTTP_SELECTIVE_LOGGING_INDEX = 1;

        // system.applicationHost/log
        //####################################################

        /// <summary>
        /// Represents the value for the centralLogFileMode of the system.applicationHost/log element.
        /// </summary>
        /// <remarks>
        /// The constant value is '2'.
        /// </remarks>
        public const int CENTRAL_LOG_FILE_MODE_INDEX = 2;
        /// <summary>
        /// Represents the value for the logInUTF8 of the system.applicationHost/log element.
        /// </summary>
        /// <remarks>
        /// The constant value is '3'.
        /// </remarks>
        public const int CENTRAL_LOG_IN_UTF8_INDEX = 3;

        // common to all logging
        //####################################################
        
        /// <summary>
        /// Represents the value for the enabled attribute of all logging elements.
        /// </summary>
        /// <remarks>
        /// The constant value is '4'.
        /// </remarks>
        public const int ENABLED_INDEX = 4;

        /// <summary>
        /// Represents the value for the directory attribute of the system.applicationHost/log/centralBinaryLogFile or system.applicationHost/log/centralW3cLogFile element.
        /// </summary>
        /// <remarks>
        /// The constant value is '5'.
        /// </remarks>
        public const int DIRECTORY_INDEX = 5;
        
        /// <summary>
        /// Represents the value for the period attribute of the system.applicationHost/log/centralBinaryLogFile or system.applicationHost/log/centralW3cLogFile element.
        /// </summary>
        /// <remarks>
        /// The constant value is '6'.
        /// </remarks>
        public const int PERIOD_INDEX = 6;
        
        /// <summary>
        /// Represents the value for the truncateSize attribute of all logging elements.
        /// </summary>
        /// <remarks>
        /// The constant value is '7'.
        /// </remarks>
        public const int TRUNCATE_SIZE_INDEX = 7;
        
        /// <summary>
        /// Represents the value for the localTimeRollover attribute of all logging elements.
        /// </summary>
        /// <remarks>
        /// The constant value is '8'.
        /// </remarks>
        public const int LOCAL_TIME_ROLLOVER_INDEX = 8;

        // common to:
        //   system.applicationHost/log/centralW3cLogFile
        //   system.applicationHost/sites/siteDefaults
        //   system.applicationHost/SiteLogFile
        //####################################################
        
        /// <summary>
        /// Represents the value for the logExtFileFlags attribute of all logging elements.
        /// </summary>
        /// <remarks>
        /// The constant value is '9'.
        /// </remarks>
        public const int LOG_EXT_FILE_FLAGS_INDEX = 9;

        // system.applicationHost/sites/site
        //####################################################

        /// <summary>
        /// Represents the value for the logFormat attribute of logging elements.
        /// </summary>
        /// <remarks>
        /// The constant value is '10'.
        /// </remarks>
        public const int LOG_FILE_FORMAT_INDEX = 10;

        // storage groups
        //####################################################
        
        /// <summary>
        /// Represents the property bag position for the log element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '11'.
        /// </remarks>
        public const int LOG_ELEMENT_INDEX = 11;
        
        /// <summary>
        /// Represents the property bag position for the binary element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '12'.
        /// </remarks>
        public const int BINARY_ELEMENT_INDEX = 12;
        
        /// <summary>
        /// Represents the property bag position for the W3C element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '13'.
        /// </remarks>
        public const int W3C_ELEMENT_INDEX = 13;
        
        /// <summary>
        /// Represents the property bag position for the Site element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '14'.
        /// </remarks>
        public const int SITE_ELEMENT_INDEX = 14;
        
        /// <summary>
        /// Represents the property bag position for the HTTP element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '15'.
        /// </remarks>
        public const int HTTP_ELEMENT_INDEX = 15;

        /// <summary>
        /// Represents the property bag position for the site default element values.
        /// </summary>
        /// <remarks>
        /// The constant value is '15'.
        /// </remarks>
        public const int SITE_DEFAULTS_ELEMENT_INDEX = 16;

        // schema state
        //####################################################
        
        /// <summary>
        /// Represents the value position for the locked attribute values.
        /// </summary>
        /// <remarks>
        /// The constant value is '40'.
        /// </remarks>
        public const int IS_LOCKED_INDEX = 40;

        /// <summary>
        /// Represents the value position for the read only attribute values.
        /// </summary>
        /// <remarks>
        /// The constant value is '40'.
        /// </remarks>
        public const int IS_READ_ONLY_INDEX = 41;
        

    }
}
// ReSharper restore InconsistentNaming